package com.ojoin.ojoin.eb_spider.domain;

import java.io.Serializable;
import java.util.Date;
import java.util.List;

import com.ojoin.trade.supplyloan_core.web.domain.TbSlPlatformUser;

public class AlipayAccount implements Serializable {

	/**
	 * 是主账号
	 */
	public final static String MAIN = "main";

	/**
	 * 绑定使用中
	 */
	public final static String COMMON = "common";

	/**
	 * 天猫平台账号
	 */

	private List<TbSlPlatformUser> users;

	/**
	 * 店铺名称
	 */
	private String nameOfShop;

	/**
	 * 登陆用账号
	 */
	private String loginUsername;

	private String username;

	private String password;
	/**
	 * 账号状态，是否为主账号
	 */
	private String statues;

	private String loginType;

	/**
	 * 当次监控完成时间
	 */

	private Date checkedtime;

	/**
	 * 检测过程中的异常封装
	 */
	private AlipayCheckException alipayCheckException = new AlipayCheckException();

	/**
	 * 标砖信息封装
	 */
	private AlipayCheckException standard;

	private boolean needCheck;

	public AlipayAccount(List<TbSlPlatformUser> users, String username,
			String loginUsername, String password, String statues,
			String loginType, String nameOfShop, boolean needCheck) {
		this.users = users;
		this.username = username;
		this.loginUsername = loginUsername;
		this.password = password;
		this.statues = statues;
		this.loginType = loginType;
		this.setNameOfShop(nameOfShop);
		this.needCheck = needCheck;
	}

	public String getUsername() {
		return username;
	}

	public void setUsername(String username) {
		this.username = username;
	}

	public String getPassword() {
		return password;
	}

	public void setPassword(String password) {
		this.password = password;
	}

	public String getStatues() {
		return statues;
	}

	public void setStatues(String statues) {
		this.statues = statues;
	}

	public String getLoginType() {
		return loginType;
	}

	public void setLoginType(String loginType) {
		this.loginType = loginType;
	}

	public Date getCheckedtime() {
		return checkedtime;
	}

	public void setCheckedtime(Date checkedtime) {
		this.checkedtime = checkedtime;
	}

	public String getLoginUsername() {
		return loginUsername;
	}

	public void setLoginUsername(String loginUsername) {
		this.loginUsername = loginUsername;
	}

	public String getNameOfShop() {
		return nameOfShop;
	}

	public void setNameOfShop(String nameOfShop) {
		this.nameOfShop = nameOfShop;
	}

	/**
	 * 账号状态，是否为主账号
	 */

	public String getStatuesName() {
		if (statues.equals(MAIN)) {
			return "主账号";
		} else if (statues.equals(COMMON)) {
			return "关联账号";
		} else {
			return "";
		}

	}

	public AlipayCheckException getAlipayCheckException() {
		return alipayCheckException;
	}

	public void setAlipayCheckException(
			AlipayCheckException alipayCheckException) {
		this.alipayCheckException = alipayCheckException;
	}

	public boolean isNeedCheck() {
		return needCheck;
	}

	public void setNeedCheck(boolean needCheck) {
		this.needCheck = needCheck;
	}

	public AlipayCheckException getStandard() {
		return standard;
	}

	public void setStandard(AlipayCheckException standard) {
		this.standard = standard;
	}

	public List<TbSlPlatformUser> getUsers() {
		return users;
	}

	public void setUsers(List<TbSlPlatformUser> users) {
		this.users = users;
	}

}
